#include    <iostream>

#include    <TestFunction.h>
#include    <RootFinder.h>

int main()
{
    TestFunction    myFunc;
    RealList        roots;

    RootFinder::FindRoots(myFunc, 1.0, 50.01, roots);

    std::cout << "roots.size() = " << roots.size() << std::endl;
    for (RealListCI i = roots.begin(); i != roots.end(); ++i) {
        Real    val;
        myFunc.GetValue(*i, val);
        std::cout << "  root = " << *i << ", myFunc(root) = " << val << std::endl;
    }

    return 0;
}
